#define _CRT_SECURE_NO_WARNINGS 1
#include <stdio.h>

int Fact(int n)
{
	int ret = 1;
	for (int i = 1;i <= n;i++)
	{
		ret *= i;
	}
	return ret;
}

int main()
{
	int n = 0;
	int ret = 0;
	scanf("%d", &n);
	ret = Fact(n);
	printf("%d", ret);
	return 0;
}